<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>yuan</title>
    <style>
        input{
            margin-bottom: 20px;
        }
    </style>
</head>
<body>


    <span>圆的半径:</span><input type="text" placeholder="半径" id="a">
    <br>
    <span>圆的周长:</span><input type="text" placeholder="周长" id="b">
    <br>
    <span>圆的面积:</span><input type="text" placeholder="面积" id="c">

    <script>

        /*圆的半径*/
        var p =Math.PI;
        console.log(p);

        var t =prompt("输入圆的半径")
        t = Number(t);
        /*圆的周长 = 直径 x π = 半径 x 2 xπ */
        var zc = t * 2 * p;
        /*圆的面积 = 半径的平方 x π = 半径 x 半径 x π */
        var mj = t * t * p;

        document.querySelector("#a").value =t;
        document.querySelector("#b").value =zc;
        document.querySelector("#c").value =mj;

    </script>







<script src="script.js"></script>
</body>
</html>